#ifndef IObjectVisitor_h__
#define IObjectVisitor_h__

#include <string>
#include "Platform.h"

namespace le
{
	class IObjectVisitor
	{
	public:
		IObjectVisitor() {}
		virtual ~IObjectVisitor() {}

		virtual bool Load(const char* fileName) = 0;
		virtual bool Save(const char* fileName) = 0;
		virtual bool IsReading() const = 0;
		virtual void MarkForWriting() = 0;

		virtual bool EnterNode(const char* nodeName) = 0;
		virtual bool ExitNode() = 0;
		virtual int32 GetCount(const char* nodeName) const = 0;

		virtual bool Visit(const char* name, int32& value, const int32 defaultValue) = 0;
		virtual bool Visit(const char* name, float& value, const float defaultValue) = 0;
		virtual bool Visit(const char* name, std::string& value, const std::string& defaultValue) = 0;

		static le::IObjectVisitor* CreateObjectVisitor();
	};
}

#endif // IObjectVisitor_h__